//
//  LTViewController.m
//  testAdv
//
//  Created by zheng ji on 14-3-30.
//  Copyright (c) 2014年 jxw. All rights reserved.
//

#import "LTViewController.h"
#import "GADBannerView.h"
@interface LTViewController ()
{
    GADBannerView* bannerView_;
}
@end

@implementation LTViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
    bannerView_ = [[GADBannerView alloc]
                   initWithFrame:CGRectMake(0.0,
                                            0.0 ,
                                            GAD_SIZE_320x50.width,
                                            GAD_SIZE_320x50.height)];    // 指定广告单元ID。
    
    bannerView_.adUnitID = @"a15325556e7d6c3";
    
    bannerView_.rootViewController = self;
    [self.view addSubview:bannerView_];
    GADRequest *request = [GADRequest request];
    // request.testDevices = @[ GAD_SIMULATOR_ID ];
    [bannerView_ loadRequest:request];
    
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
